package com.knowledge.service;

import com.knowledge.entity.Article;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

public interface ArticleService {
    Article createArticle(Article article, Long authorId);
    Article updateArticle(Long id, Article article);
    void deleteArticle(Long id);
    Article getArticle(Long id);
    Page<Article> getAllArticles(Pageable pageable);
    Page<Article> getArticlesByAuthor(Long authorId, Pageable pageable);
    Page<Article> searchArticles(String keyword, Pageable pageable);
    Page<Article> getHotArticles(Pageable pageable);
    Article incrementViewCount(Long id);
    Article incrementLikeCount(Long id);
} 